<template>
  <div class="row justify-start">
    <q-input
      v-for="f in field"
      :key="f.name"
      :type="f.type? f.type: 'text'"
      :rows="f.type==='textarea'? 3: 0"
      :class="f.type==='textarea'? 'col-12': 'col-lg-3 col-md-3 col-sm-4 col-xs-6'"
      v-model="form[f.name]" :label="f.label"
      stack-label readonly borderless dense/>
  </div>
</template>

<script>
export default {
  props: {
    form: {
      type: Object,
      required: true
    },
    field: {
      type: Array,
      required: true
    }
  },
  data () {
    return {}
  }
}
</script>

<style lang="stylus" scoped>

</style>
